package com.ruoyi.system.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.system.mapper.AppUserPushMapper;
import com.ruoyi.system.domain.AppUserPush;
import com.ruoyi.system.service.IAppUserPushService;
import com.ruoyi.common.core.text.Convert;

/**
 * 用户推送记录Service业务层处理
 * 
 * @author ruoyi
 * @date 2021-07-31
 */
@Service
public class AppUserPushServiceImpl implements IAppUserPushService
{
    @Autowired
    private AppUserPushMapper appUserPushMapper;

    /**
     * 查询用户推送记录
     * 
     * @param userName 用户推送记录ID
     * @return 用户推送记录
     */
    @Override
    public AppUserPush selectAppUserPushById(String userName)
    {
        return appUserPushMapper.selectAppUserPushById(userName);
    }

    /**
     * 查询用户推送记录列表
     * 
     * @param appUserPush 用户推送记录
     * @return 用户推送记录
     */
    @Override
    public List<AppUserPush> selectAppUserPushList(AppUserPush appUserPush)
    {
        return appUserPushMapper.selectAppUserPushList(appUserPush);
    }

    /**
     * 新增用户推送记录
     * 
     * @param appUserPush 用户推送记录
     * @return 结果
     */
    @Override
    public int insertAppUserPush(AppUserPush appUserPush)
    {
        return appUserPushMapper.insertAppUserPush(appUserPush);
    }

    /**
     * 修改用户推送记录
     * 
     * @param appUserPush 用户推送记录
     * @return 结果
     */
    @Override
    public int updateAppUserPush(AppUserPush appUserPush)
    {
        return appUserPushMapper.updateAppUserPush(appUserPush);
    }

    /**
     * 删除用户推送记录对象
     * 
     * @param ids 需要删除的数据ID
     * @return 结果
     */
    @Override
    public int deleteAppUserPushByIds(String ids)
    {
        return appUserPushMapper.deleteAppUserPushByIds(Convert.toStrArray(ids));
    }

    /**
     * 删除用户推送记录信息
     * 
     * @param userName 用户推送记录ID
     * @return 结果
     */
    @Override
    public int deleteAppUserPushById(String userName)
    {
        return appUserPushMapper.deleteAppUserPushById(userName);
    }

    /**
     * 删除
     * @param appUserPush
     * @return
     */
    @Override
    public int del(AppUserPush appUserPush) {
        return appUserPushMapper.del(appUserPush);
    }
}
